//
//  YMModelForHotVideo.m
//  VideoPic
//
//  Created by apple on 16/3/22.
//  Copyright © 2016年 apple. All rights reserved.
//

#import "YMModelForHotVideo.h"

@implementation YMModelForHotVideo

- (void)setValue:(id)value forUndefinedKey:(NSString *)key {
    if ([key isEqualToString:@"stat"]) {
        _vcntNice = [value objectForKey:@"vcntNice"];
    }
    if ([key isEqualToString:@"pic"]) {
        _picUrl = [NSString stringWithFormat:@"%@%@",[value objectForKey:@"base"], [value objectForKey:@"m"]];
    }
    if ([key isEqualToString:@"stream"]) {
        _videoUrl = [NSString stringWithFormat:@"%@%@.mp4", [value objectForKey:@"base"], _videoID];
    }
    if ([key isEqualToString:@"ext"]) {
        _videoLength = [value objectForKey:@"length"];
        _videoLengthNice = [value objectForKey:@"lengthNice"];
        _finishTime = [value objectForKey:@"finishTime"];
        _finishTimeNice = [value objectForKey:@"finishTimeNice"];
        _videoTitle = [value objectForKey:@"t"];
        _videoFTitle = [value objectForKey:@"ft"];
        
        NSDictionary *dic = [value objectForKey:@"owner"];
        _userID = [dic objectForKey:@"suid"];
        _userLoginName = [dic objectForKey:@"loginName"];
        _userNick = [dic objectForKey:@"nick"];
        _userFace = [dic objectForKey:@"icon"];
        _userVip = [dic objectForKey:@"v"];
    }

    
    
    
}

@end
